import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/biz/teacher/` + url, ...arg)

/**
 * 教师Api接口管理器
 *
 * @author sanda
 * @date  2024/11/28 16:36
 **/
export default {
	// 获取教师分页
	eduTeacherPage(data) {
		return request('page', data, 'get')
	},
	// 获取教师列表
	eduTeacherList(data) {
		return request('list', data, 'get')
	},
	// 提交教师表单 edit为true时为编辑，默认为新增
	eduTeacherSubmitForm(data, edit = false) {
		return request(edit ? 'add' : 'edit', data)
	},
	// 删除教师
	eduTeacherDelete(data) {
		return request('delete', data)
	},
	// 获取教师详情
	eduTeacherDetail(data) {
		return request('detail', data, 'get')
	}
}
